﻿<%@ Page Language="C#" AutoEventWireup="true" Inherits="masterdata_PeopleList" CodeFile="PeopleList_ProvinceManger.aspx.cs" MasterPageFile="~/MasterPage.master" %>

 
<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
    <title>人员列表</title>

    <script src="../JavaScript/common.js" type="text/javascript"></script>

     

</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="ContentPlaceHolder1" runat="Server">
    <div>
        <table id="wsd_inputtable">
            <tr>
                <td class="tabletitle" colspan="6">
                    查询条件
                </td>
            </tr>
            <tr>
                <td class="tablefield">
                    姓名:
                </td> 
                <td>
                    <asp:TextBox runat="server" ID="txtName"></asp:TextBox>
                </td>
                <td class="tablefield">
                    性别:
                </td>
                <td>
                    <asp:DropDownList runat="server" ID="ddlSex" Width="130">
                        <asp:ListItem Text="--所有--" Value="-1"></asp:ListItem>
                        <asp:ListItem Text="男" Value="0"></asp:ListItem>
                        <asp:ListItem Text="女" Value="1"></asp:ListItem>
                    </asp:DropDownList>
                </td>
                <td class="tablefield">
                    职位:
                </td>
                <td>
                    <asp:DropDownList ID="ddlPosition" Width="130px" runat="server">
                    </asp:DropDownList>
                </td>
            </tr>
            <tr>
                <td class="tablefield">
                    部门:
                </td>
                <td>
                    <asp:TextBox ID="txtOrg" runat="server" onkeydown="alert('请选择部门');return false;"></asp:TextBox>
                    <img src="../Resources/Images/search.png" alt="查找" style="cursor: pointer;" onclick="openPopup('../System/PopupOrganization.aspx?NameControlId=<%# txtOrg.UniqueID %>&ValueControlId=<%# txtHidOrg.UniqueID %>&SelectType=multi','','300','500');" />
                </td>
                <td class="tablefield">
                    有效:
                </td>
                <td>
                    <asp:DropDownList ID="ddlValid" runat="server" Width="130">
                        <asp:ListItem Value="" Text="--所有--" Selected="True"></asp:ListItem>
                        <asp:ListItem Value="1" Text="--有效--"></asp:ListItem>
                        <asp:ListItem Value="0" Text="--无效--"></asp:ListItem>
                    </asp:DropDownList>
                </td>
                <td class="buttonarea" colspan="2">
                    <input id="txtHidOrg" runat="server" type="hidden" />
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" ErrorMessage="请选择部门!"
                        ControlToValidate="txtOrg"></asp:RequiredFieldValidator>
                    <asp:Button ID="btnQuery" runat="server" Text="查  询" CssClass="wsd_button2" OnClick="btnQuery_Click" />
                    &nbsp;
                    <asp:Button ID="btnExport" runat="server" class="wsd_button2" Text="导出Excel" OnClick="btnExport_Click" />
                    &nbsp;
                    <input type="button" class="wsd_button2" size="47" value="重  置" name="reset" onclick="clearForm('form1')" />
                </td>
            </tr>
        </table>
        <br />
        <table id="wsd_inputtable">
            <tr>
                <td class="tabletitle">
                    人员列表
                </td>
                <td class="tabletitle">
                   
                </td>
            </tr>
        </table>
        <table id="wsd_listtable">
            <tr>
                <td>
                    <asp:GridView Width="100%" ID="GridView1" runat="server" AutoGenerateColumns="False"
                        EmptyDataText="没有可显示的数据." EmptyDataRowStyle-Font-Bold="true" EmptyDataRowStyle-HorizontalAlign="Center"
                        OnRowDataBound="Grid_RowDataBound" AllowPaging="True" OnPageIndexChanging="GridView1_PageIndexChanging"
                        PageSize="20">
                        <HeaderStyle CssClass="titlist" />
                        <EmptyDataRowStyle HorizontalAlign="Center" Font-Bold="True"></EmptyDataRowStyle>
                        <Columns>
                            <asp:HyperLinkField DataNavigateUrlFields="ID" DataNavigateUrlFormatString="PersonEdit.aspx?id={0}"
                                DataTextField="NAME" HeaderText="人员姓名" ControlStyle-Font-Underline="false">
                                <ControlStyle Font-Underline="False"></ControlStyle>
                            </asp:HyperLinkField>
                            <asp:BoundField HeaderText="性别" DataField="SEX" />
                            <asp:BoundField DataField="ORGNAME" HeaderText="部门" />
                            <asp:BoundField HeaderText="职位" DataField="POSITION" />
                            <asp:BoundField HeaderText="电话" DataField="TELEPHONE" />
                            <asp:BoundField HeaderText="身份证" DataField="IDENTITY" />
                            <asp:BoundField HeaderText="邮件地址" DataField="E_MAIL" />
                            <asp:TemplateField HeaderText="有效" ItemStyle-HorizontalAlign="center" HeaderStyle-HorizontalAlign="center">
                                <ItemTemplate>
                                    <b>
                                        <%# Eval("IsValid").ToString()  == "1" ? "<font size='3' color='green'>√</font>" : "<font size='3' color='red'>×</font>"%></b>
                                </ItemTemplate>
                                <HeaderStyle HorizontalAlign="Center"></HeaderStyle>
                                <ItemStyle HorizontalAlign="Center"></ItemStyle>
                            </asp:TemplateField>
                        </Columns>
                        <PagerSettings FirstPageText="首页" LastPageText="尾页" Mode="NumericFirstLast" PageButtonCount="30" />
                        <RowStyle CssClass="evenline" />
                        <AlternatingRowStyle CssClass="oddline" />
                    </asp:GridView>
                </td>
            </tr>
        </table>
        <br />
        <table id="wsd_inputtable">
            <tr>
                <td width="100%" class="tabletitle">
                    操作选项
                </td>
            </tr>
            <tr>
                <td class="buttonarea">
                    <input id="btnAdd" type="button" value="新  增" onclick="location.href='PersonEdit.aspx'"
                        class="wsd_button2" causesvalidation="False" />
                </td>
            </tr>
        </table>
    </div>
 </asp:Content>
